package com.space.dao;

import com.space.entity.Flight;

import java.util.List;
import java.util.Map;

/**
 * @author : 港某
 * @date : 2020/2/13 16:41
 */
public interface FlightDao {

    //查询

    List<Flight> selectAllFlight();

    List<Integer> selectSomeFlightByHot();

    List<Flight> selectFlightByStartCityId(int cityId);

    List<Flight> selectFlightByEndCityId(int cityId);

    List<Flight> selectSomeFlightByStartTime(Map<String, String> map);

    List<Flight> selectSomeFlightByPage(Map<String, String> map);

    List<Flight> selectAllFlightBySearch(Map<String, String> map);

    List<Flight> selectSomeFlightByUserSearch(Map<String, String> map);

    List<Flight> selectSomeFlightByExpense(Map<String, String> map);

    //操作

    void insertFlight(Map<String, String> map);

    Flight selectFlightById(int flightId);

    void deleteFlightById(int flightId);

    void updateFlightById(Map<String, String> map);

    //统计

    int selectAllFlightCount();

    int selectFlightCountByStatus1();

    int selectFlightCountByStatus2();

    int selectFlightCountByStatus3();

    //job

    void updateFlightStartStatusId();

    void updateFlightEndStatusId();
}
